import java.text.DateFormat;
import java.text.SimpleDateFormat;
import java.util.Date;

public class Books {			// Creating Books class

	String ISBN;				// Specifying each content as required
	int Copy;
	String Title;
	String Author;
	String Publisher;
	int Year;
	int Stats;
	Date BorrowDate;
	Date ReturnDate;
	int LibraryCardNumber;
	
	
	Books() {					//construct object Books
		ISBN = "";
		Copy = 0;
		Title = "";
		Author = "";
		Publisher = "";
		Year = 0;
		Stats = 000;
		BorrowDate = null;
		ReturnDate = null;
		LibraryCardNumber = 0000;

	}

	String getBooks1(String ISBN) {			// Creating constructors
		return ISBN;

	}

	int getBooks2(int Copy) {
		return Copy;

	}

	String getBooks3(String Title) {
		return Title;

	}

	String getBooks4(String Author) {
		return Author;

	}

	String getBooks5(String Publisher) {
		return Publisher;

	}

	int getBooks6(int Year) {
		return Year;

	}

	int getBooks7(int Stats) {
		return Stats;

	}

	Date getBooks8(Date BorrowDate) {
		return BorrowDate;

	}

	Date getBooks9(Date ReturnDate) {
		return ReturnDate;

	}

	int getBooks1(int LibraryCardNumber) {
		return LibraryCardNumber;

	}

	void setBooks1(String newISBN) {			//Creating methods to set the new values
		ISBN = newISBN;

	}

	void setBooks2(int newCopy) {
		Copy = newCopy;

	}

	void setBooks3(String newTitle) {
		Title = newTitle;

	}

	void setBooks4(String newAuthor) {
		Author = newAuthor;

	}

	void setBooks5(String newPublisher) {
		Publisher = newPublisher;

	}

	void setBooks6(int newYear) {
		Year = newYear;

	}

	void setBooks7(int newStats) {

		Stats = newStats;

	}

	void setBooks8(Date borrowDate) {
		BorrowDate = borrowDate;

	}

	void setBooks9(Date newReturnDate) {
		ReturnDate = newReturnDate;

	}

	void setBooks10(int newLibraryCardNumber) {
		LibraryCardNumber = newLibraryCardNumber;

	}

	String getFileFormat() {		// How the printing will be on the text file

		DateFormat df = new SimpleDateFormat("yyMMdd");

		String fileFormat = ISBN + "#" + Copy + "#" + Title + "#" + Author
				+ "#" + Publisher + "#" + Year + "#" + Stats + "#"
				+ df.format(BorrowDate) ; // Getting the Date
		if (ReturnDate != null && LibraryCardNumber != 0) {		// if they returnDate and library exists print them
			fileFormat += "#" + df.format(ReturnDate) + "#" + LibraryCardNumber
					+ "#";

		}

		return fileFormat;			// Return the method

	}

}